package org.tinygroup.trans.xstream.base;

import org.tinygroup.trans.xstream.manager.XStreamConvertService;
import org.tinygroup.trans.xstream.util.XStreamConvertUtil;

public class XStreamConvertImpl implements XStreamConvertService {
	static {
		try {
			Class<?> clazz = Class
					.forName("org.tinygroup.trans.xstream.base.XStreamConvertImpl");
			XStreamConvertUtil
					.setXStreamConvertService((XStreamConvertService) clazz
							.newInstance());
		} catch (Exception e) {
			throw new RuntimeException("设置XStreamConvertService失败，失败原因："+e.getMessage());
		}
	}

	/**
	 * 根据场景号返回XStreamPackageName
	 * 
	 * @param scene
	 * @return
	 */
	public String getXStreamPackageName(String scene) {
		return XStreamSceneMappingManager.getXStreamPackageName(scene);
	}

}
